package archive

import (
	"github.com/xi2/xz"
	"io"
)

var Xzip = &compressXzip{}

type compressXzip struct{}

func (receiver *compressXzip) Reader(reader io.Reader) (io.Reader, error) {
	xzipReader, err := xz.NewReader(reader, 0)

	return xzipReader, err
}

// func (receiver *compressXzip) Writer(writer io.Writer) (io.Writer, error) {
// 	xzipWriter, err := xz.NewWriter(writer, 0)
//
// 	return tar.NewWriter(xzipWriter), err
// }
